Remove runtime checks for < that.
//------------------------------------------------------------------------
int main(int argc, char**argv)
{
-#if (QT_VERSION < QT_VERSION_CHECK(5, 0, 0))
- // Qt 5.0 uses QString::fromUtf8 to convert from character pointers
- // and QBytreArrays to QStrings while previous version of Qt used
- // QString::fromAscii. QString::fromAscii used the codec set
- // by QTextCode::setCodecForCStrings.
- // This makes the conversion consistent between Qt4 and Qt5.
- QTextCodec::setCodecForCStrings(QTextCodec::codecForName("UTF-8"));
+#if (QT_VERSION < QT_VERSION_CHECK(5, 2, 0))
+ #error this version of Qt is not supported.
#endif
QApplication *app;
QUrl downloadUrl;
updateStatus_ = updateCurrent; // Current until proven guilty.
-#if (QT_VERSION < QT_VERSION_CHECK(5, 0, 0))
- for (int i = 0; i < (int) upgrades.length(); i++) {
-#else
for (int i = 0; i < upgrades.length(); i++) {
-#endif
QDomNode upgradeNode = upgrades.item(i);
QDomElement upgrade = upgradeNode.toElement();
(void) new gpsbabel::UsAsciiCodec(); /* make sure a US-ASCII codec is available */
-#if (QT_VERSION < QT_VERSION_CHECK(5, 0, 0))
- // Qt 5.0 uses QString::fromUtf8 to convert from character pointers
- // and QBytreArrays to QStrings while previous version of Qt used
- // QString::fromAscii. QString::fromAscii used the codec set
- // by QTextCode::setCodecForCStrings.
- // This makes the converstion consistent between Qt4 and Qt5.
- QTextCodec::setCodecForCStrings(QTextCodec::codecForName("UTF-8"));
+#if (QT_VERSION < QT_VERSION_CHECK(5, 2, 0))
+ #error This version of Qt is not supported.
#endif
// The first invocation of QTextCodec::codecForLocale() may result in LC_ALL being set to the native environment